<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>

<f:view>
<h:form id="form02">
	<f:loadBundle var="msg" basename="#{statWizard.resourceBundleName}" />
	
	<h:inputHidden value="#{statWizard.selectedServiceName}"/>
	<h:outputText value="[#{statWizard.selectedServiceName}]"/>
	<h:commandButton id="link01" value="showList" action="showList" />
	
	
	<f:verbatim><div style="height:10px;"></div></f:verbatim>
		
	<h:dataTable id="serviceProperties" value="#{statWizard.serviceProperties}" var="property">   
		<h:column>
    		<f:facet name="header">
      			<h:outputText  value=""/>
    		</f:facet>     		
     		<h:outputText value="#{msg[property.attrName]}"/>
  		</h:column>
		<h:column>
    		<f:facet name="header">
      			<h:outputText  value=""/>
    		</f:facet>
     		<h:outputText value="#{property.attrValue}"/>
  		</h:column>
	</h:dataTable> 
	
	<f:verbatim><div style="height:10px;"></div></f:verbatim>
	
	<f:verbatim><table><tr><td></f:verbatim>
	<h:outputText  value="#{msg.dateStart}"/>
	<f:verbatim></td><td></f:verbatim>
	<h:selectOneMenu id="dayFrom" value="#{statWizard.dayFrom}">
  		<f:selectItems value="#{statWizard.calendarDays}" />
	</h:selectOneMenu>
	<f:verbatim></td><td></f:verbatim>
	<h:selectOneMenu id="monthFrom" value="#{statWizard.monthFrom}">
  		<f:selectItems value="#{statWizard.calendarMonths}" />
	</h:selectOneMenu>
	<f:verbatim></td><td></f:verbatim>
	<h:selectOneMenu id="yearFrom" value="#{statWizard.yearFrom}">
  		<f:selectItems value="#{statWizard.calendarYears}" />
	</h:selectOneMenu>
	<f:verbatim></td><td></f:verbatim>
	<h:outputText  value="#{msg.dateEnd}"/>
	<f:verbatim></td><td></f:verbatim>
	<h:selectOneMenu id="dayTo" value="#{statWizard.dayTo}">
  		<f:selectItems value="#{statWizard.calendarDays}" />
	</h:selectOneMenu>
	<f:verbatim></td><td></f:verbatim>
	<h:selectOneMenu id="monthTo" value="#{statWizard.monthTo}">
  		<f:selectItems value="#{statWizard.calendarMonths}" />
	</h:selectOneMenu>
	<f:verbatim></td><td></f:verbatim>
	<h:selectOneMenu id="yearTo" value="#{statWizard.yearTo}">
  		<f:selectItems value="#{statWizard.calendarYears}" />
	</h:selectOneMenu>
	<f:verbatim></td><td></f:verbatim>
	<h:commandButton id="link02" value="#{msg.applyFilter}" action="applyFilter" />
	<f:verbatim></td></tr></table></f:verbatim>
	
	
	<f:verbatim><div style="height:10px;"></div></f:verbatim>
	
	<f:verbatim><div style="height:10px;"></div></f:verbatim>
	
	<f:verbatim><table></f:verbatim>
	
	<c:set var="detailes" value= "${statWizard.serviceDetailes}"/> 
	
	<c:forEach items="${detailes.columns}" var="column"> 		
    		<f:verbatim><th></f:verbatim>
      			<c:out  value="${msg[column]}"/>    		
    		<f:verbatim></th></f:verbatim>  		
  	</c:forEach>
	<c:forEach items="${detailes.rows}" var="row">
	   <f:verbatim><tr></f:verbatim> 	
	   <c:forEach items="${detailes.columns}" var="column"> 		
    		<f:verbatim><td></f:verbatim>
      			<c:out  value="${row[column]}"/>    		
    		<f:verbatim></td></f:verbatim>
  	   </c:forEach>
  	   <f:verbatim></tr></f:verbatim>			
	</c:forEach>
	<f:verbatim></table></f:verbatim> 	
  
</h:form>

</f:view>